/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */

package pkg.data;

import java.util.Calendar;
import java.util.Date;
import org.primefaces.model.DefaultScheduleEvent;

/**
 *
 * @author Shengyi_Chen
 */
public class AnotherScheduleEvent extends DefaultScheduleEvent{
    
    private String title;
    private String className;
    private String location;
    private int studentNumber;
    private int timeZone;
    private String labView;
    
    private String podID;
    private String instructorName;
    private Date theBeginningOfStartDay;
    private Date theEndingOfStartDay;

    public AnotherScheduleEvent(String new_, Date date, Date date0) {
        super(new_, date, date0);
    }

    public AnotherScheduleEvent() {
        super();
    }

    /**
     * @return the location
     */
    public String getLocation() {
        return location;
    }

    /**
     * @param location the location to set
     */
    public void setLocation(String location) {
        this.location = location;
    }

    /**
     * @return the studentNumber
     */
    public int getStudentNumber() {
        return studentNumber;
    }

    /**
     * @param studentNumber the studentNumber to set
     */
    public void setStudentNumber(int studentNumber) {
        this.studentNumber = studentNumber;
    }

    /**
     * @return the podID
     */
    public String getPodID() {
        return podID;
    }

    /**
     * @param podID the podID to set
     */
    public void setPodID(String podID) {
        this.podID = podID;
    }

    /**
     * @return the instructorName
     */
    public String getInstructorName() {
        return instructorName;
    }

    /**
     * @param instructorName the instructorName to set
     */
    public void setInstructorName(String instructorName) {
        this.instructorName = instructorName;
    }

    /**
     * @return the theBeginningOfStartDay
     */
    public Date getTheBeginningOfStartDay() {
        Date d = super.getStartDate();
        Calendar c = Calendar.getInstance();
        if (d != null){
            c.setTime(d);
            c.set(Calendar.HOUR_OF_DAY, 0);
            c.set(Calendar.MINUTE, 30);
        }else{
            c.set(Calendar.HOUR_OF_DAY, 0);
            c.set(Calendar.MINUTE, 30);
        }
        theBeginningOfStartDay = c.getTime();
        
        return theBeginningOfStartDay;
    }

    /**
     * @return the theEndingOfStartDay
     */
    public Date getTheEndingOfStartDay() {
        Date d = getTheBeginningOfStartDay();
        Calendar c = Calendar.getInstance();
        c.setTime(d);
        c.set(Calendar.HOUR_OF_DAY, 23);
        c.set(Calendar.MINUTE, 30);
        theEndingOfStartDay = c.getTime();
        return theEndingOfStartDay;
    }
    
}
